Skip to content

Puppet 8+ compat support: require stdlib 9, and switch to use stdlib::to_json#285

Merged
kenyon merged 4 commits into
voxpupuli:masterfrom
fifieldt:patch-1
Jul 8, 2026
Merged

Puppet 8+ compat support: require stdlib 9, and switch to use stdlib::to_json#285
kenyon merged 4 commits into
voxpupuli:masterfrom
fifieldt:patch-1

Conversation

@fifieldt

@fifieldt fifieldt commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Pull Request (PR) description

In openvox 8, using to_json emits a deprecation warning:

Puppet This function is deprecated, please use stdlib::to_json instead. at ["/etc/puppetlabs/code/modules/rsyslog/templates/modules.epp", 13]

This patch changes the use of to_json in modules.epp so that it uses stdlib::to_json, making deprecation warnings go away :)

Stdlib 9 is now required.

This Pull Request (PR) fixes the following issues

n/a

In openvox 8, using `to_json` emits a deprecation warning:

```Puppet This function is deprecated, please use stdlib::to_json instead. at ["/etc/puppetlabs/code/modules/rsyslog/templates/modules.epp", 13]```

This patch changes the use of to_json in modules.epp so that it uses stdlib::to_json if available, and if not uses to_json. This should result in compatibility across a wide range of puppet versions, while making deprecation warnings go away :)
Comment thread templates/modules.epp Outdated
fifieldt and others added 2 commits July 9, 2026 08:44
Co-authored-by: Kenyon Ralph <kenyon@kenyonralph.com>
Per @kenyon , it's now time to set the lower bound requirement for
stdlib to the version that came out in 2023.
@fifieldt
fifieldt requested a review from kenyon July 8, 2026 22:48
@fifieldt

fifieldt commented Jul 8, 2026

Copy link
Copy Markdown
Contributor Author

Thanks @kenyon, I've simplified the change to the template and updated metadata.json to require stdlib 9+

@fifieldt fifieldt changed the title 8+ compat support: to_json --> stdlib::to_json 8+ compat support: require stdlib 9, and switch to use stdlib::to_json Jul 8, 2026
Comment thread templates/modules.epp Outdated
Co-authored-by: Kenyon Ralph <kenyon@kenyonralph.com>
@kenyon
kenyon merged commit 7a03a19 into voxpupuli:master Jul 8, 2026
15 checks passed
@kenyon kenyon changed the title 8+ compat support: require stdlib 9, and switch to use stdlib::to_json Puppet 8+ compat support: require stdlib 9, and switch to use stdlib::to_json Jul 8, 2026
@kenyon kenyon added the backwards-incompatible This change will lead to a major version bump for the next release label Jul 8, 2026
@fifieldt
fifieldt deleted the patch-1 branch July 8, 2026 23:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backwards-incompatible This change will lead to a major version bump for the next release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants